import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 17655
 * Date: 2025-05-20
 * Time: 16:46
 */
public class test1 {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        // 注意 hasNext 和 hasNextLine 的区别
        while (in.hasNextInt()) { // 注意 while 处理多个 case
            int n = in.nextInt();
            long sum = 1;
            for(int i=1;i<=n;i++){
                sum *= i;
            }
            int count = 0;
            while(sum!=0){
                long num = sum%10;
                if(num==0){
                    count++;
                }
                sum/=10;
            }
            System.out.println(count);
        }
    }
}
